/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package models;
import java.io.Serializable;
/**
 *
 * @author Thijs
 */
public class Roll implements Serializable
{
    private long rollnumber;
    private String name;
    
    public Roll(long rollnumber, String name){
        if (rollnumber < 1) {
			throw new IllegalArgumentException(
			"Customer number may not be negative, value = " + rollnumber);
		}
		if (name == null) {
			throw new NullPointerException("Customer name may not be empty");
		}
        this.setName(name);
        this.setRollnumber(rollnumber);
    }

    /**
     * @return the rollnumber
     */
    public long getRollnumber()
    {
        return rollnumber;
    }

    /**
     * @param rollnumber the rollnumber to set
     */
    public void setRollnumber(long rollnumber)
    {
        this.rollnumber = rollnumber;
    }

    /**
     * @return the name
     */
    public String getName()
    {
        return name;
    }

    /**
     * @param name the name to set
     */
    public void setName(String name)
    {
        this.name = name;
    }
}
